-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
Updating and re-opening PR #48129 #50541
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Co-authored-by: Matthew Roeschke <[email protected]>
@@ -761,7 +761,10 @@ def _add_offset(self, offset) -> DatetimeArray: | |||
assert not isinstance(offset, Tick) | |||
|
|||
if self.tz is not None: | |||
values = self.tz_localize(None) | |||
if not offset._use_relativedelta: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is there a viable way to handle this inside the Offset code? in theory the DTA code shouldn't need to know anything about _use_relativedelta
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The issue is with how these dates are localized, and I don't believe there is a good way to modify this in the Offset code.
] | ||
) | ||
offset1 = DateOffset(hours=3) | ||
offset2 = DateOffset(days=1) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks like this only tests the DateOffset class, for which _use_relativedelta can be True. but the code you changed affects a bunch of other classes
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alright, I'll try and work on some tests for the other classes.
This pull request is stale because it has been open for thirty days with no activity. Please update and respond to this comment if you're still interested in working on this. |
Sorry this went stale, I've been really busy lately, I think I'll be able to find time to clean this up soon. |
Thanks for the pull request, but it appears to have gone stale. If interested in continuing, please merge in the main branch, address any review comments and/or failing tests, and we can reopen. |
doc/source/whatsnew/vX.X.X.rst
file if fixing a bug or adding a new feature.